package com.zbb.exam_system.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;

/**
 * @author zbbstart
 * @date 2021/2/9 - 16:57
 */
@Data
@TableName("user_role")
@ApiModel(value = "用户角色对象", description = "封装了用户的各个角色编号后得到的一个实体对象")
public class UserRole implements Serializable {
    private static final long serialVersionUID = -121071201350495158L;
    @TableId(value = "id",type = IdType.AUTO)
    @ApiModelProperty(name = "id", value = "用户角色表自动主键", example = "1")
    private Integer id;
    @TableField("user_id")
    @ApiModelProperty(name = "userId", value = "用户编号", example = "1")
    private Integer userId;
    @TableField("role_id")
    @ApiModelProperty(name = "roleId", value = "角色编号", example = "1")
    private Integer roleId;
}
